package com.newtouch.bxzs.database.synchronize.service;


import com.newtouch.bxzs.database.synchronize.model.CustomerBO;
import com.newtouch.bxzs.database.synchronize.model.OrganizationBO;
import com.newtouch.bxzs.database.synchronize.model.SynProductVO;
import com.newtouch.bxzs.database.synchronize.model.UserBO;
import com.newtouch.bxzs.database.synchronize.model.achievement.AchievementPolicyVO;
import com.newtouch.bxzs.database.synchronize.model.achievement.AchievementVO;
import com.newtouch.bxzs.database.synchronize.model.income.IncomeDetailVO;
import com.newtouch.bxzs.database.synchronize.model.income.IncomeEstimateVO;
import com.newtouch.bxzs.database.synchronize.model.income.IncomeVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.stereotype.Component;
import org.springframework.web.bind.annotation.PostMapping;

import java.util.List;

/**
 * 同步本端数据
 * <p>
 * <b>History:</b>
 * <table border="1">
 * <tr>
 * <th>Date</th>
 * <th>Operator</th>
 * <th>Memo</th>
 * </tr>
 * <tr>
 * <td>2020/12/25 16:17</td>
 * <td>Amour</td>
 * <td>Create</td>
 * </tr>
 * </table>
 *
 * @author yuanjie
 * @version 1.0.0
 * @since 1.0.0
 */

@Component
@FeignClient(url = "${synchronize.url}",name = "synchronize")
public interface SynchronizeOwnClient {
    /**
     * 同步客户信息
     * @return List<CustomerBO>
     */
    @PostMapping(value="/dabaBase/getCustomer")
    List<CustomerBO> synchronizedCustomer();

    /**
     * 同步本端机构信息
     * @return List<OrganizationBO>
     */
    @PostMapping(value="/dabaBase/getBankOrganization")
    List<OrganizationBO>synchronizeOwnOrgan();

    /**
     * 同步本端用户信息
     * @return List<UserBO>
     */
    @PostMapping(value="/dabaBase/getBankUser")
    List<UserBO>getOwnUser();

    /**
     * 同步业绩数据
     * @return List<AchievementVO>
     */
    @PostMapping(value="/statistics/getAchievement")
    List<AchievementVO>getAchievement();


    /**
     * 同步业绩明细数据
     * @return List<AchievementPolicyVO>
     */
    @PostMapping(value="/statistics/getAchievementPolicy")
    List<AchievementPolicyVO>getAchievementPolicy();

    /**
     * 同步个人收入数据
     * @return List<IncomeVO>
     */
    @PostMapping(value="/statistics/getIncome")
    List<IncomeVO>getIncome();

    /**
     * 同步个人收入明细数据
     * @return List<IncomeDetailVO>
     */
    @PostMapping(value="/statistics/getIncomeDetail")
    List<IncomeDetailVO>getIncomeDetail();

    /**
     * 同步预估收入汇总数据
     * @return List<IncomeEstimateVO>
     */
    @PostMapping(value="/statistics/getIncomeEstimate")
    List<IncomeEstimateVO>getIncomeEstimate();

    /**
     * 同步预估收入明细数据
     * @return List<IncomeDetailVO>
     */
    @PostMapping(value="/statistics/getIncomeEstimateDetail")
    List<IncomeDetailVO>getIncomeEstimateDetail();

    /**
     * 同步产品
     * @return List<SynProductVO>
     */
    @PostMapping(value="/product/getProductList")
    List<SynProductVO>getProductList();

}
